<!DOCTYPE html> 
<html> 
	<head>
		<!-- required -->
		<meta http-equiv="X-UA-Compatible" content="IE=9,chrome=1">

		<script type="text/javascript">
			// configure framework using fluidOptions (a global variable) 
			var fluidOptions = {
				// if it should run in debug mode
				// by default this is set to false
				isDebug: true,
				
				// reconfigure named plugins of the framework
				// provide an alternate implementation for required ones by giving the JS file name for a named plugin, 
				// leave it empty if inbuilt version of the plugin is to be used
				// in case inbuild plugin is not required - use "off" keyword (use with care, framework may stop working)
				namedPlugins: {
					// with the help of fluidOptions, any core plugin can be turned off 
					// or an external version can be configured
					
					// must be defined (if a custom application plugin is to be used)
					app: "%APP%/app.*.js"
					
					// NOTE: instead of using app.debug.js, it used app.*.js. This flexibity ensures that
					// as per the debug mode, framework automatically picks the app.debug.js or app.min.js 
					// file. For release builds, build engine will take care of generating *.min.js file 
					// for all files which are named as *.debug.js
				}
			};
			
			// called when framework is completely loaded and navigaton to a page should happen now. 
			// Note, this is a fall-back method and is called only when framework's default navigation
			// engine is not in use and in that case either application plugin is not in use or does
			// not take care of this by having $f.app.onNavigationASync() function.
			// params:
			//	callback (function): function to call after navigation is done
			// returns (void):			
			function onNavigationASync(callback) {
				// This example requires core or above package to work
				if ($f.info.version.package.isKernel() || $f.info.version.package.isCore()) {
					$("body").append("<strong>This example cannot run with '" + $f.info.version.package.type + "' package.</strong>");
					return;
				};
				
				// once you are done with your logic of showing UI, you MUST CALL
				// given callback to complete frameowrk loading and firing post
				// navigation events
				// IMPORTANT: If this is not done, framework will not be loaded
				// completely and state of application will be unstable
				if (isFunction(callback)) {
					callback();
				};
			};
		</script>
		
		<!-- for DEMO UI use only -->
		<link href="../../res/bootstrap.min.css" rel="stylesheet">
		<link href="../../res/bootstrap-responsive.min.css" rel="stylesheet">
		<link href="../../res/styles.css" rel="stylesheet">
		<!-- -->
		
	</head>
	<body> 
		<!-- required -->
		<applet name="fsa" code="fsa.class" archive="../../fsa.jar" style="position:absolute; left:-1px;" height="1" width="1"></applet> 

		<!-- NOTE: There are no UI elements defined here, instead defaultPage layout will be loaded -->
		
		<!-- refer framework JS (as last item in body) -->
		<script type="text/javascript" src="../../fluid.debug.js"></script> 	
		
		<!-- for DEMO UI use only -->
		<script src="../../res/bootstrap.min.js"></script>
		<script src="../../res/general.js"></script>
		<!-- -->
	</body> 
</html> 
